These same two or three tests are currently duplicated
in several places, with separate static variables. Lets
do this in one place.
debug_flags = flags;
}
+gboolean
+gtk_simulate_touchscreen (void)
+{
+ static gint test_touchscreen;
+
+ if (test_touchscreen == 0)
+ test_touchscreen = g_getenv ("GTK_TEST_TOUCHSCREEN") != NULL ? 1 : -1;
+
+ return test_touchscreen > 0 || (debug_flags & GTK_DEBUG_TOUCHSCREEN) != 0;
+ }
+
/**
* gtk_get_option_group:
* @open_default_display: whether to open the default display
void _gtk_load_dll_with_libgtk3_manifest (const char *dllname);
#endif
+gboolean gtk_simulate_touchscreen (void);
+
G_END_DECLS
#endif /* __GTK_PRIVATE_H__ */